package demo;

public class Bird extends Animals implements IFlying, IRunning {
    public Bird(String name, int age) {
        super(name, age);//帮助父类进行构造，用super来进行访问父类
    }

    @Override
    public void eat() {
        System.out.println(this.name + "正在吃饭!");
    }

    @Override
    public void fly() {
        System.out.println(this.name + "正在用翅膀飞！");
    }

    @Override
    public void run() {
        System.out.println(this.name + "正在用鸟腿跑！");
    }
}
